//#include <QDebug>
//#include "ttscore.h"


//using namespace std;

//GoogleTTS::GoogleTTS()
//{
//     qDebug()<<"get";
////    connect(&player, SIGNAL(stateChanged(QMediaPlayer::State state)),this,SLOT(void PlayerFinished(QMediaPlayer::State state)));
//}

//void GoogleTTS::Speak(QString text)
//{
////    QString full_link;
////    full_link.append(LINK);
////    full_link.append(QUrl::toPercentEncoding(text));
////    qDebug()<<"Full link: "<<full_link;
////    player.setVolume(100);
////    player.setMedia(QUrl(full_link)); //-- more info on: http://doc.qt.io/qt-5/qmediaplayer.html
////    //  player.setMedia(QUrl("http://www.freeinfosociety.com/media/sounds/2518.mp3"));
////    //--- simular usage
////     //player.setMedia(QUrl::fromLocalFile("D:/tts2.mp3"));
////        //player.setMedia(QUrl("http://www.tonycuffe.com/mp3/tailtoddle_lo.mp3"));
////        //player.setMedia(QUrl("http://download.wavetlan.com/SVV/Media/HTTP/MP4/ConvertedFiles/Media-Convert/Unsupported/test7.mp4"));
////    player.setPlaybackRate(1.5);
////    player.play();
//    qDebug()<<"done";
//}


//void GoogleTTS::PlayerFinished(QMediaPlayer::State state)
//{
//    qDebug()<<"get";
//}



////////////---------------- PLAY GOURND ----------
////   GoogleTTS TTS;
////    TTS.sayText("Hallo world");

////    QUrl imageUrl("http://demo.dreamfoxmedia.nl/wordpress/wp-content/uploads/2014/09/icon-256x256.png");
////    m_pImgCtrl = new FileDownloader(imageUrl, this);

////    connect(m_pImgCtrl, SIGNAL(downloaded()), SLOT(loadImage()));

//    QString full_link;
//    full_link.append(LINK);
//    full_link.append(QUrl::toPercentEncoding(ui->textEdit->toPlainText()));
//    qDebug()<<"Full link: "<<full_link;
//    player.setVolume(100);
//    player.setMedia(QUrl(full_link)); //-- more info on: http://doc.qt.io/qt-5/qmediaplayer.html
//  //  player.setMedia(QUrl("http://www.freeinfosociety.com/media/sounds/2518.mp3"));
//    //--- simular usage
//     //player.setMedia(QUrl::fromLocalFile("D:/tts2.mp3"));
//        //player.setMedia(QUrl("http://www.tonycuffe.com/mp3/tailtoddle_lo.mp3"));
//        //player.setMedia(QUrl("http://download.wavetlan.com/SVV/Media/HTTP/MP4/ConvertedFiles/Media-Convert/Unsupported/test7.mp4"));
//    player.setPlaybackRate(1.5);
//    player.play()
